package com.example.presentshopping.ui.activity

import BaseRecyclerAdapter
import BaseRecyclerHolder
import android.annotation.SuppressLint
import android.content.Intent
import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.text.Html
import android.widget.TextView
import androidx.fragment.app.Fragment
import com.example.presentshopping.R
import com.example.presentshopping.config.base.BaseMvpActivity
import com.example.presentshopping.config.bean.LocationBean
import com.example.presentshopping.config.bean.MyearningsBean
import com.example.presentshopping.mvp.presenter.PublicPresenter
import com.example.presentshopping.net.http.HttpRequest
import com.example.presentshopping.net.http.HttpURL
import com.example.presentshopping.ui.fragment.earnings.TodatearninFragment
import com.example.presentshopping.utils.ToastUtil
import com.example.presentshopping.utils.tool.GsonUtils
import kotlinx.android.synthetic.main.activity_location.*
import kotlinx.android.synthetic.main.activity_myearnings.*
import kotlinx.android.synthetic.main.activity_myearnings.SpecialViewPager
import kotlinx.android.synthetic.main.activity_myearnings.tablayout
import kotlinx.android.synthetic.main.activity_myearnings.title_main_tv
import kotlinx.android.synthetic.main.activity_team.*

class MyearningsActivity :BaseMvpActivity() {

    private val strTitle = arrayOf("昨日收益","今日收益")
    override val layoutId: Int
        get() = R.layout.activity_myearnings

    override fun initView(savedInstanceState: Bundle?) {
        title_main_tv.leftBackImageTv.setOnClickListener { finish() }
        val pageViews = ArrayList<Fragment>()
        pageViews.add(TodatearninFragment(this,"1"))
        pageViews.add(TodatearninFragment(this,"2"))
        tablayout.setViewPager(SpecialViewPager, strTitle, this, pageViews)


    }



    override fun onDestroy() {
        super.onDestroy()
    }

    override fun showToast(msg: String?) {
     ToastUtil.showMsg(msg)
    }

    override fun onSuccess(data: String?) {


          }

    override fun onFailure(e: Throwable?, code: Int, msg: String?, isNetWorkError: Boolean) {

    }
}